/*
 *      Copyright (c) 2018-2028, Chill Zhuang All rights reserved.
 *
 *  Redistribution and use in source and binary forms, with or without
 *  modification, are permitted provided that the following conditions are met:
 *
 *  Redistributions of source code must retain the above copyright notice,
 *  this list of conditions and the following disclaimer.
 *  Redistributions in binary form must reproduce the above copyright
 *  notice, this list of conditions and the following disclaimer in the
 *  documentation and/or other materials provided with the distribution.
 *  Neither the name of the dreamlu.net developer nor the names of its
 *  contributors may be used to endorse or promote products derived from
 *  this software without specific prior written permission.
 *  Author: Chill 庄骞 (smallchill@163.com)
 */
package org.springblade.mes.system.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.springblade.core.tenant.mp.TenantEntity;

import javax.validation.constraints.Email;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;

/**
 * 联系人表实体类
 *
 * @author shiwei
 * @since 2021-02-23
 */
@Data
@TableName("sale_customer_linkman")
@EqualsAndHashCode(callSuper = true)
@ApiModel(value = "CustomerLinkman对象", description = "联系人表")
public class CustomerLinkman extends TenantEntity {
    private static final long serialVersionUID = 1L;

    @NotNull(message = "客户的id不能为null")
    @ApiModelProperty(value = "客户的id", required = true)
    private String customerId;

    @ApiModelProperty(value = "客户姓名", required = true)
    private String customerName;

    @NotNull
    @NotBlank
    @ApiModelProperty(value = "联系人姓名", required = true)
    private String linkmanName;

    @NotNull
    @NotBlank
    @ApiModelProperty(value = "联系人电话", required = true)
    private String linkPhone;

    @NotNull
    @NotBlank
    @ApiModelProperty(value = "联系人部门", required = true)
    private String dept;

    @NotNull
    @NotBlank
    @ApiModelProperty(value = "联系人职位", required = true)
    private String post;

    @ApiModelProperty(value = "联系人固定电话")
    private String fixedPhone;

    @ApiModelProperty(value = "联系人手机号")
    private String phone;

    @ApiModelProperty(value = "联系人传真")
    private String fax;

    @NotNull
    @ApiModelProperty(value = "联系人使用语言", required = true)
    private String useLanguage;
    @Email
    @ApiModelProperty(value = "联系人邮箱地址")
    private String email;

    @ApiModelProperty(value = "客户编号")
    private String customerNumber;

    @ApiModelProperty(value = "审批状态")
    @TableField(exist = false)
    private String statusStr;
    @ApiModelProperty(value = "使用语言")
    @TableField(exist = false)
    private String useLanguageStr;

    @ApiModelProperty(value = "创建人姓名")
    @TableField(exist = false)
    private String createUserstr;
    private String createUserName;
    @ApiModelProperty(value = "通讯地址")
    @TableField(exist = false)
    private String addressstr;

    /**
     * 更改项id
     */
    @ApiModelProperty(value = "更改项id")
    private Long changeId;

    /**
     * 新旧(1,旧，2，新)
     */
    @ApiModelProperty(value = "新旧")
    private String type;

    /**
     * 变更原因
     */
    @ApiModelProperty(value = "变更原因")
    private String changeReason;
}
